package util;

import jxl.read.biff.BiffException;
import obj.*;

import java.io.IOException;
import java.util.List;

public class GoodsHelper {
    public static void main(String[] args) throws IOException, BiffException {
        List<Accum> accums = Accum.parseAccums("se", 2);
        for (Accum accum : accums) {
            System.out.println(accum.name);
            System.out.println(accum.url);
            System.out.println(accum.photo);
            int i = 0;
            for (String model : accum.devices) {
                System.out.println("\t" + accum.brandName + " " + model);
                System.out.println("\t" + accum.deviceURLs.get(i++));
                System.out.println(accum.art);
            }
        }
//        List<Body> bodies = Body.parseBodies("se", 2);
//        for (Body body : bodies) {
//            System.out.println(body.model + " " + body.url);
//        }
//        List<Charger> chargers = Charger.parseChargers("se", 2, true);
//        for (Charger charger : chargers) {
//            System.out.println(charger.name);
//            int i = 0;
//            for (String model : charger.models) {
//                System.out.println("\t" + charger.brandName + " " + model);
//                System.out.println("\t" + charger.modelURLs.get(i++));
//            }
//        }
//        List<Headset> headsets = Headset.parseHeadsets("se", 2);
//        for (Headset headset : headsets) {
//            System.out.println(headset.name);
//            int i = 0;
//            for (String model : headset.devices) {
//                System.out.println("\t" + headset.brandName + " " + model);
//                System.out.println("\t" + headset.deviceURLs.get(i++));
//            }
//        }
//        List<Templ> phones = Templ.parseTempls("phones", "remont", 100);
//        for (Templ phone : phones) {
//            System.out.println(phone.vendor);
//            int i = 0;
//            for (String model : phone.models) {
//                System.out.println("\t" + phone.vendor + " " + model);
//                System.out.println(phone.modelUrls.get(i++));
//            }
//        }
    }
}
